package org.linlinjava.litemall.web.dto;

import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.linlinjava.litemall.db.dto.WebOrderGoodsRemarkDTO;
import org.linlinjava.litemall.web.vo.OrderGoodsAddAccessoryVO;
import org.linlinjava.litemall.web.vo.OrderGoodsAddPropertyVO;
import org.linlinjava.litemall.web.vo.order.OrderFormulaSpecificationsMaterialVO;
import org.linlinjava.litemall.web.vo.order.OrderPackageCheckOutVO;
import org.linlinjava.litemall.web.vo.order.OrderPackageGoodsFormulasVO;

import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class WebGoodsCheckOut {
    @ApiModelProperty(value = "商品id")
    @NotNull
    private Integer goodsId;

    @ApiModelProperty(value = "购买数量")
    @NotNull
    private Integer number;

    @ApiModelProperty(value = "订单税费")
    private List<WebOrderGodsTaxDTO> godsTax;

    @ApiModelProperty(value = "商品税费")
    private Map<String,BigDecimal> goodsTax;
    @ApiModelProperty(value = "商品总税费（GST+HST+PST）")
    private BigDecimal taxPrice = new BigDecimal(0.00);

    @ApiModelProperty("商品单价(规格价格)")
    private BigDecimal unitPrice;

    @ApiModelProperty("商品售价(单价+辅料的价格)")
    private BigDecimal sellingPrice;

    @ApiModelProperty("商品优惠后的价格")
    private BigDecimal discountPrice;

    @ApiModelProperty("商品总价")
    private BigDecimal price;

    @ApiModelProperty("商品备注(传递一个数组或集合转换成字符串)")
    List<WebOrderGoodsRemarkDTO> remark;

    @ApiModelProperty(value = "属性列表")
    private OrderPackageGoodsFormulasVO goodsFormulas;

   /* @ApiModelProperty("配方 原料")
    private List<OrderFormulaSpecificationsMaterialVO> formulaSpecificationsMaterials;*/

    @ApiModelProperty(value = "属性列表")
    private List<OrderGoodsAddPropertyVO> propertyList;

    @ApiModelProperty(value = "规格id")
    @NotNull
    private Integer specificationId;


    //套餐数据
    /*@ApiModelProperty(value = "套餐ID")
    private Integer  setMealId;

    @ApiModelProperty(value = "套餐数量")
    private Integer  setMealNumber;

    @ApiModelProperty(value = "套餐名称")
    private String setMealName;

    @ApiModelProperty("订单套餐")
    private List<OrderPackageCheckOutVO> setMealgoods;*/

/*
    @ApiModelProperty(value = "辅料列表")
    private List<WebOrderGoodsAccessoryDTO> accessoryList;

    @ApiModelProperty("是否配方")
    private Boolean isFormula;

    @ApiModelProperty("商品备注(传递一个数组或集合转换成字符串)")
    private List<Map> remark1;*/

}
